﻿using System.ComponentModel.DataAnnotations;
using YWM.Dto;

namespace PLC.Interface.Groups
{
    public class GroupDto : EntityDto
    {
        [Required(ErrorMessage = "组名称不能为空"), StringLength(50, ErrorMessage = "组名称不能超过50个字符")]
        public string DisplayName { get; set; }

        public ushort StartAddress { get; set; }

        public ushort Length { get; set; }

        [Required(ErrorMessage = "请选择存储区")]
        public byte? StoreArea { get; set; }

        [StringLength(255, ErrorMessage = "描述不能超过255个字符")]
        public string Description { get; set; }
    }
}
